package cn.kgc.biz.controller;

import cn.kgc.biz.service.HotelService;
import cn.kgc.dto.Dto;
import cn.kgc.vo.FeatureVo;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/api/hotel/")
public class HotelController {
    @Resource
    private HotelService hotelService;
    @GetMapping("getvideodesc/{hotelId}")
    public Dto getVideoDesc(@PathVariable("hotelId") String hotelId){
        return hotelService.getHotelVideodesc(Long.parseLong(hotelId));
    }
    @GetMapping("queryhoteldetails/{hotelId}")
    public Dto queryHotelDetails(@PathVariable("hotelId") String hotelId){
        return hotelService.queryhoteldetails(Long.parseLong(hotelId));
    }
    @GetMapping("queryhotelfacilities/{hotelId}")
    public Dto queryHotelFacilities(@PathVariable("hotelId") String hotelId){
        return hotelService.queryHotelFacilities(Long.parseLong(hotelId));
    }

    @GetMapping("queryhotelpolicy/{hotelId}")
    public Dto queryHotelPolicy(@PathVariable("hotelId") String hotelId){
        return hotelService.queryHotelPolicy(Long.parseLong(hotelId));
    }
    @GetMapping("getimg/{hotelId}")
    public Dto getImg(@PathVariable("hotelId") String hotelId){
        return hotelService.getImg(Long.parseLong(hotelId));
    }
    @GetMapping("queryhotcity/{isChina}")
    public Dto queryHotCity(@PathVariable("isChina") Long isChina){
        return hotelService.queryHotCity(isChina);
    }
    @GetMapping("queryhotelfeature")
    public Dto queryHotelFeature(){
        return hotelService.queryHotelFeature();
    }
}
